#ifndef _LOGGER_H_
#define _LOGGER_H_

#if defined( DEBUG ) | defined( _DEBUG )

#include <string>
#include <vector>

class Logger
{
	public:

		/**
		* @brief					Initializes Logging system. This MUST be called before writing logs
		* @param[in] fileName		The log (message) to write.
		* @param[in] isSaveToFile	If set to true, every log is saved to a file as it is written
		* @param[in] isKeepLogs		If set to true, logs are held in a list to be referenced. Use if you want to display your logs on screen
		*/
		static void Initialize( const char* fileName, bool isSaveToFile = true );
		//static void Initialize(const char* fileName, bool isSaveToFile = true, bool isKeepLogs = true);
		static void Shutdown( void );
		static void Write( const char* log, ... );

	//public:
		//static const std::vector<std::string>& GetLogs( void ) { return m_logs; }
		//static void Clear( void ) { m_logs.clear(); }

	protected:
		//static std::vector<std::string>	m_logs;
		static const char*				m_fileName;
		static bool						m_isSaveToFile;
		//static bool						m_isKeepLogs;
		static FILE*					m_file;
};

/**
* @brief				Writes a log. Whether to save it to file or keep a list of log depends on the setting at Initialize()
* @param[in] message	The log (message) to write.
*/
#define LOG( message, ... )	{ Logger::Write( message, __VA_ARGS__ ); }

#else
	#define	LOG( message )
#endif

#endif // end of _LOGGER_H_